<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <link href="https://xcximg.juseyun.com/assets/css/bootstrap.min.css" rel="stylesheet" />
    <link rel="stylesheet" href="https://xcximg.juseyun.com/assets/css/style.css"/>
    <link href="https://xcximg.juseyun.com/assets/css/codemirror.css" rel="stylesheet">
    <link rel="stylesheet" href="https://xcximg.juseyun.com/assets/css/ace.min.css" />
    <link rel="stylesheet" href="https://xcximg.juseyun.com/assets/font/css/font-awesome.min.css" />
    <script src="https://xcximg.juseyun.com/assets/js/jquery-1.9.1.min.js"></script>
    <script src="https://xcximg.juseyun.com/assets/js/bootstrap.min.js"></script>
    <script src="https://xcximg.juseyun.com/assets/js/typeahead-bs2.min.js"></script>
    <script src="https://xcximg.juseyun.com/assets/js/jquery.dataTables.min.js"></script>
    <script src="https://xcximg.juseyun.com/assets/js/jquery.dataTables.bootstrap.js"></script>
    <script src="https://xcximg.juseyun.com/assets/layer/layer.js" type="text/javascript" ></script>
    <script src="https://xcximg.juseyun.com/assets/laydate/laydate.js" type="text/javascript"></script>
    <script src="https://xcximg.juseyun.com/assets/js/displayPart.js" type="text/javascript"></script>
    <title>审核</title>
</head>

<body>
<div class="margin clearfix">
    <div class="Shops_Audit">
        <div class="prompt">当前共有<b><%=data.length%></b>位医生申请审核</div>
        <!--申请列表-->
        <div class="audit_list">
            <table class="table table-striped table-bordered table-hover" id="sample-table">
                <thead>
                <tr>
                    <th width="180px">医生名称</th>
                    <th width="120px">所属分类</th>
                    <th width="120px">医院</th>
                    <th width="">简介</th>
                    <th width="150px">添加时间</th>
                    <th width="100px">审核状态</th>
                    <th width="250px">操作</th>
                </tr>
                </thead>
                <tbody>
                <%for(var i=0;i<data.length;i++){%>
                <tr data-id="<%=data[i]._id%>">
                    <td><%=data[i].name%></td>
                    <td><%=data[i].department%></td>
                    <td><%=data[i].institution%></td>
                    <td><%=data[i].profile%></td>
                    <td><%=data[i].time%></td>
                    <td>待审核</td>
                    <td class="td-manage">
                        <a  href="detailed?id=<%=data[i]._id%>" class="btn btn-xs btn-info Refund_detailed">详细</a>
                        <a  href="javascript:;"  onclick="member_del(this,'1')" class="btn btn-xs btn-danger" >删除</a>
                    </td>
                </tr>
                <%}%>
                </tbody>
            </table>

        </div>
    </div>
</div>
</body>
</html>
<script>
    $(function () {
        $(".displayPart").displayPart();
    });
    $(function() {
        var oTable1 = $('#sample-table').dataTable( {
            //"aaSorting": [],//默认第几个排序
            "bStateSave": true,//状态保存
            //"dom": 't',
            "bFilter":false,
            "aoColumnDefs": [
                //{"bVisible": false, "aTargets": [ 3 ]} //控制列的隐藏显示
                {"orderable":false,"aTargets":[0,1,2,3,4,5,6]}// 制定列不参与排序
            ] } );
        $('table th input:checkbox').on('click' , function(){
            var that = this;
            $(this).closest('table').find('tr > td:first-child input:checkbox')
                    .each(function(){
                        this.checked = that.checked;
                        $(this).closest('tr').toggleClass('selected');
                    });

        });
    })

    function member_del(obj,id){
        layer.confirm('确认要删除吗？',{icon:0,},function(index){
            $(obj).parents("tr").remove();
            layer.msg('已删除!',{icon:1,time:1000});
        });
    }

    var index = parent.layer.getFrameIndex(window.name);
    parent.layer.iframeAuto(index);
    $('.Refund_detailed').on('click', function(){
        var cname = $(this).attr("title");
        var chref = $(this).attr("href");
        var cnames = parent.$('.Current_page').html();
        var herf = parent.$("#iframe").attr("src");
        parent.$('#parentIframe').html(cname);
        parent.$('#iframe').attr("src",chref).ready();;
        parent.$('#parentIframe').css("display","inline-block");
        parent.$('.Current_page').attr({"name":herf,"href":"javascript:void(0)"}).css({"color":"#4c8fbd","cursor":"pointer"});
        parent.layer.close(index);

    });
</script>
